package com.cwnu.onlinemall.service;

import com.cwnu.onlinemall.mapper.MallSignMapper;
import com.cwnu.onlinemall.pojo.MallSign;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class SignServiceImpl implements SignService{
    @Autowired
    MallSignMapper mallSignMapper;

    @Override
    public List<MallSign> selectAll() {
        return mallSignMapper.selectByExample(null);
    }

    @Override
    public MallSign selectById(Integer id) {
        MallSign mallSign = mallSignMapper.selectByPrimaryKey(id);
        return mallSign;
    }

    @Override
    public Integer insert(MallSign mallSign) {
        int insertRow = mallSignMapper.insertSelective(mallSign);
        return insertRow;
    }
}
